/*
 * @Author: kongjingchao
 * @Date: 2023-03-31 17:55:43
 * @Last Modified by: kongjingchao
 * @Last Modified time: 2023-04-28 13:47:21
 * @Description: SVG显示
 * @Copyright (c) 2023 CFCA [http://www.cfca.com.cn] All rights reserved.
 */

<template>
  <svg class="svg-icon" aria-hidden="true">
    <use :xlink:href="iconName" />
  </svg>
</template>

<script lang="ts" setup>
import {ref} from 'vue';
const props = defineProps<{svgName ?:string}>();
const iconName = ref(`#icon-${props.svgName}`);

</script>

<style lang="scss" scoped>
.svg-icon {
  vertical-align: -0.15em;
  fill: currentColor;
  overflow: hidden;
}
</style>
